<?php
$paginator->options(array('update' => 'contentalt', 'indicator' => 'spinner'));
?> 



<div class="requirementTypes index">
<h2><?php __('Requirements');?></h2>
<p>
<?php
echo $paginator->counter(array(
'format' => __('Page %page% of %pages% [ showing %current% types of requirements out of %count% ]', true)
));
?></p>



<?php
$i = 0;
foreach ($requirementTypes as $requirementType):
	$class = null;
	if ($i++ % 2 == 0) {
		$class = ' class="altrow"';
	}
?>

			
			
			
<fieldset><legend>
<a href="<?php echo "".Router::url("/", true); ?>requirements/list_requirements/<?php echo "".$requirementType['RequirementType']['id']; ?>/more" class="lightwindow page-options" params="lightwindow_type=external" title="<?php echo "".$requirementType['RequirementType']['name']; ?>" style=" font-size:18px;"><?php echo $requirementType['RequirementType']['name']; ?></a>
</legend>

<div id="requirements_<?php echo "".$i; ?>">

<div id="requirements_list_<?php echo "".$i; ?>">
</div>
<script type="text/javascript">
<?php echo $ajax->remoteFunction(
array(
'url' => array( 'controller' => 'requirements', 'action' => 'list_requirements', $requirementType['RequirementType']['id'] ),
'update' => 'requirements_list_'.$i
)
); ?>
</script>


</div>

<div class="actions">

+ <a href="<?php echo "".Router::url("/", true); ?>requirements/new_requirement" class="lightwindow page-options" params="lightwindow_type=external,lightwindow_width=500,lightwindow_height=650" title="Add a new Requirement" >New Requirment</a>


</div>

</fieldset>
			


<?php endforeach; ?>
</div>

<div class="actions">

+ <a href="<?php echo "".Router::url("/", true); ?>requirement_types/new_requirement_type" class="lightwindow page-options" params="lightwindow_type=external,lightwindow_width=500,lightwindow_height=250" title="Add a new Requirement Type" >New Requirment Type</a>


</div>


<div class="paging" align="center">
<table>
<tr><th>
	<?php echo $paginator->prev('<< '.__('previous', true), array(), null, array('class'=>'disabled'));?>  
	</th>
	<th>
	<?php echo $paginator->numbers();?>
	</th>
	<th>
	 <?php echo $paginator->next(__('next', true).' >>', array(), null, array('class'=>'disabled'));?>
	 </th>
	 </tr>
	 </table>
</div>


